package homework;

import java.util.Random;

public class java09 {
	public static void main(String[] args) {
		int[] arr= {1,2,3,4,5};
		Random r=new Random();
		int temp;
		for(int i=0;i<arr.length;i++) {
			int n=r.nextInt(4);
			if(n==0) {
				continue;
			}
			temp=arr[0];
			arr[0]=arr[n];
			arr[n]=temp;
		}
		for(int i=0;i<arr.length;i++) {
			System.out.print(arr[i]+" ");
		}
		
	}
}
